From: Daiki Ueno Date: Thu, 3 Jan 2013 23:56:51 +0000 (+0900) Subject: * epg.el (epg--start): Ignore errors when /dev/fd/0 does not exist. X-Git-Tag: archive/raspbian/1%29.2+1-2+rpi1^2~5^2~3615^2~1153 X-Git-Url: https://dgit.raspbian.org/%22http:/www.example.com/cgi/%22https:/www.github.com/%22bookmarks:///%22http:/www.example.com/cgi/%22https:/www.github.com/%22bookmarks:/?a=commitdiff_plain;h=c2cf1829ddd72c4fa24e7def8d94e8b2ee937a03;p=emacs.git * epg.el (epg--start): Ignore errors when /dev/fd/0 does not exist. --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 3aae01b9f1e..f327b929e56 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2013-01-03 Daiki Ueno + + * epg.el (epg--start): Ignore errors when /dev/fd/0 does not + exist. (Bug#13344) + 2013-01-03 Glenn Morris * mail/rmail.el (rmail-set-header-1): Ignore case. diff --git a/lisp/epg.el b/lisp/epg.el index 6be3ba15a97..ff32661ada9 100644 --- a/lisp/epg.el +++ b/lisp/epg.el @@ -1167,9 +1167,11 @@ This function is for internal use only." ;; use `terminal-name' here to get the real pty name for the child ;; process, though /dev/fd/0" is not portable. (with-temp-buffer - (when (= (call-process "tty" "/dev/fd/0" t) 0) - (delete-backward-char 1) - (setq terminal-name (buffer-string)))) + (condition-case nil + (when (= (call-process "tty" "/dev/fd/0" t) 0) + (delete-backward-char 1) + (setq terminal-name (buffer-string))) + (file-error))) (when terminal-name (setq process-environment (cons (concat "GPG_TTY=" terminal-name)